using JSG.BubbleShoot.ScriptableObjects;
using JSG.Car.ScriptableObjects;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.SceneManagement;
using UnityEngine.UI;


namespace JSG.BubbleShoot.UI
{
    public class MainMenuUI : MonoBehaviour
    {
        [SerializeField]
        public DataStorage m_DataStorage;
        [SerializeField, Space]
        private UIGraphicContents m_UIGraphicContents;
        [SerializeField, Space]
        private UITextContents m_UITextContentsContents;


        public GameData m_Data;
        // Start is called before the first frame update
        void Start()
        {



        }

        // Update is called once per frame
        void Update()
        {

        }

        public void BtnStart()
        {
            if (m_DataStorage.LevelUnlocked == 0)
            {
                m_DataStorage.Level = 0;
                m_DataStorage.SaveData();
                SceneManager.LoadScene("Levels");
            }
            else
            {
                UISystem.RemoveUI("MainMenUI");
                UISystem.ShowUI("LevelsUI");
            }
        }


        public void BtnExit()
        {
            Application.Quit();
        }

    }
}
